package com.lebron.kotlin.http

import com.lebron.kotlin.bean.movie.Subject
import com.lebron.kotlin.bean.movie.TheaterBean
import com.lebron.kotlin.bean.movie.USTheaterBean
import io.reactivex.Observable
import retrofit2.http.GET
import retrofit2.http.Path
import retrofit2.http.Query

/**
 * @Author lebron
 * @Date 18-7-26-下午1:49
 * 豆瓣接口
 */
interface DouBanApiService {

    /**
     * 热映的电影
     */
    @GET("movie/in_theaters")
    fun getInTheater(@Query("start") start: Int, @Query("count") count: Int): Observable<TheaterBean>

    /**
     * 即将上映
     */
    @GET("movie/coming_soon")
    fun getComingSoon(@Query("start") start: Int, @Query("count") count: Int): Observable<TheaterBean>

    /**
     * top250
     */
    @GET("movie/top250")
    fun getTop250(@Query("start") start: Int, @Query("count") count: Int): Observable<TheaterBean>

    /**
     * 北美票房榜
     */
    @GET("movie/us_box")
    fun getUSBox(@Query("start") start: Int, @Query("count") count: Int): Observable<USTheaterBean>
    /**
     * 电影条目信息
     */
    @GET("movie/subject/{id}")
    fun getSubject(@Path("id") id:String) : Observable<Subject>
}